package com.ad.platform.common.constant;

import java.util.HashMap;
import java.util.Map;

/**
 * @author:dxgong
 * @日期 2020/2/6 19:56
 * @注释
 */
public class WxConst {

    /**
     * 灵动通数据
     * start
     * */

    /**
     * 小指令appId sub_appid
     * */
    //public static final String appId = "wx873afe654eba96d4";
    /**
     * 灵动通appId sub_appid
     * */
    public static final String appId = "wxcd6dfb7ce4c93c82";

    /**
     * 小指令app secret
     * */
    //public static final String appSecret = "3233205c3ef116ae893d90618e770797";
    /**
     * 灵动通app secret
     * */
    public static final String appSecret = "948324e10fb1159e4d76bda4b5d0a5cb";


    /**
     * 小程序(小指令)商户号
     * */
    public static final String MERCHANT_NUMBER = "1575719881";


    /**
     * 小程序设备号
     * */
    public static final String XIAOZHILING = "xzl19940313";


    /**
     * 统一下单接口
     * */
    public static final String UNIFIEDORDER = "https://api.mch.weixin.qq.com/pay/unifiedorder";


    /**
     * trade_type
     * */
    public static final String TRADE_TYPE = "JSAPI";

    /**
     * sign_type
     * */
    public static final String SIGN_TYPE = "HMAC-SHA256";


    /**
     * body
     * */
    public static final String BODY = "CA崇安-微信支付";


    /**
     * 服务器ip地址
     * */
    public static  String IPV4_ = "159.75.205.29";


    /**
     * 服务器地址访问前缀
     * */
    public static String PRE_HTTP = "http://cyt2r9.port2.cn";


    /**
     * API_KEY
     * */
    public static final String API_KEY = "2441e28edcce42549c43c12bad531e32";



    /**
     * 获取access_token连接
     * */
    public static String ACCESS_TOKEN_URL = "https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential";


    /**
     * 订阅消息api
     * */
    public static  String MESSAGE = "https://api.weixin.qq.com/cgi-bin/message/subscribe/send?access_token=";


    /**
     * 模板消息api
     * */
    public static  String MESSAGE_MODEL = "https://api.weixin.qq.com/cgi-bin/message/template/send?access_token=";


    /**
     * 小指令订阅消息ID - 生成订单通知
     * */
    //public static final String  TEMPLATE_ID_1 = "4sLRplyItbyfh7G6eD87LcXqe7cidohH8vOdc7uwhQU";
    /**
     * 灵动通订阅消息ID - 生成订单通知
     * */
    public static final String  TEMPLATE_ID_1 = "jY9ixz8CDDdFSpeOuYqS4hlQzG7wo5K_YpVxU88bCf0";

    /**
     * 小指令订阅消息ID - 订单更新通知
     * */
    //public static final String TEMPLATE_ID_2 = "OFoV1ieR5lhtb5FlFXBsTddssmzsDgydhEHrSb60L6E";
    /**
     * 灵动通订阅消息ID - 订单更新通知
     * */
    public static final String TEMPLATE_ID_2 = "0BnoZDpPF4Khi8MY55xCxba74yd3nhG5mK2CmnhRzKE";


    /**
     * 模板消息ID
     * */
    public static final String  MODEL_ID_1 = "TmbeZPMu-sJw3C8dFcqF2W5Y0lHLHSdsw3yvusVnBUY";


    /**
     * 小指令-服务号-模板消息ID
     * */
    public static final String  MODEL_ID_2 = "Q5KA_HDog3Nrn6gOc2HMKxaUQQZyEHkYqXmdwbzI-AE";

    /**
     * 小指令-服务号-模板消息ID
     * */
    public static final String MODEL_ID_3 = "4WJ4WANOAD0sImf5e_jLcHLkOdE38aUB1YtrRBFo7JA";


    /**
     * 放置数据map
     * */
    public static final Map<String, String> wxMap = new HashMap<>();


    /**
     * jscode2session
     * */
    public static String JS_CODE_2_SESSION = "https://api.weixin.qq.com/sns/jscode2session?";


    /**
     * 小程序数据
     * end
     * */


    /***
     * 服务号数据
     * start
     */

    /**
     * 小指令服务号appid
     * */
    //public static final String SERVICE_APP_ID = "wxab642c2d7c8e9f19";
    /**
     * 灵动通服务号appid
     * */
    public static final String SERVICE_APP_ID = "wx2c045c0e5754d7d0";

    /**
     * 小指令服务号APP_SECRET
     * */
    //public static final String SERVICE_APP_SECRET = "93bf1b9908a320207404d553057b3c04";
    /**
     * 灵动通服务号APP_SECRET
     * */
    public static final String SERVICE_APP_SECRET = "b6f40d7abb1bc9870ddfb194d6e6b9ac";


    /**
     * 小指令服务号商户号
     * */
    //public static final String SERVICE_MERCHANT_ID = "1576333781";
    /**
     * 灵动通服务号商户号
     * */
    public static final String SERVICE_MERCHANT_ID = "1612001203";


    /**
     * 统一下单接口
     * */
    public static String SERVICE_UNIFIEDORDER = "https://api.mch.weixin.qq.com/pay/unifiedorder";

    /**
     * 添加分账方接口
     * */
    public static String PROFITS_SHARING_ADD_RECEIVER = "https://api.mch.weixin.qq.com/pay/profitsharingaddreceiver";

    /**
     * 服务上查询商户订单号(transaction_id)
     * 访问时要替换掉{out_trade_no}参数 订单id
     * param1 sp_mchid 服务商商户号
     * param1 sub_mchid 子商户商户号
     *
     * https://api.mch.weixin.qq.com/v3/pay/partner/transactions/out-trade-no/{out_trade_no}
     * */
    public static String PARTER_QUERY_TRANSACTION = "https://api.mch.weixin.qq.com/v3/pay/partner/transactions/out-trade-no";

    /**
     * 请求单次分账
     * */
    public static String PROFITS_SHARING = "https://api.mch.weixin.qq.com/secapi/pay/profitsharing";
    /**
     * 查询订单待分账金额
     * */
    public static String PROFITS_SHARING_ORDER_AMOUNT = "https://api.mch.weixin.qq.com/pay/profitsharingorderamountquery";

    /**
     * 小指令服务号SERVICE_API_KEY 秘钥
     * */
    //public static final String SERVICE_API_KEY = "B1E00C7752444B49A338C278CB338BDF";

    /**
     * 灵动通服务号SERVICE_API_KEY 秘钥
     */
    public static final String SERVICE_API_KEY = "4B277FDC530746C0B641C87F44841CD8";


    /**
     * 公众号获取access_token
     * */
    public static String SERVICE_ACCESS_TOKEN_URL = "https://api.weixin.qq.com/sns/oauth2/access_token?";


    /**
     * 获取用户信息
     * */
    public static String USER_INFO_URL = "https://api.weixin.qq.com/sns/userinfo?";


    /**
     * 服务商退款接口
     * */
    public static String SERVICE_REFUND_URL = "https://api.mch.weixin.qq.com/secapi/pay/refund";


    /**
     * 根据unionid获取用户公众号openid
     * */
    public static String SERVICE_GET_OPEN_ID_URL = "https://api.weixin.qq.com/cgi-bin/user/info?";


    /**
     * 小指令 退款证书地址
     * */
    public static String SERVICE_REFUND_PATH = "/Users/catstoo/Documents/wx-cert/1576333781_20200323_cert/apiclient_cert.p12";

    /**
     * 灵动通 退款证书地址
     * */
    //public static String SERVICE_REFUND_PATH = "/Users/catstoo/Downloads/wx-cert/apiclient_cert.p12";

    /**
     * 小指令私钥证书文件地址
     */
    public static String SERVICE_PRIVATE_KEY_PATH = "/Users/catstoo/Documents/wx-cert/1576333781_20200323_cert/apiclient_key.pem";
    /**
     * 灵动通私钥证书文件地址
     */
    //public static String SERVICE_PRIVATE_KEY_PATH = "/Users/catstoo/Downloads/wx-cert/apiclient_key.pem";

    /**
     * api_v3证书加密密钥
     */
    public static String API_V3_SECRET = "adfd95a4b3634b58b0cf3b8c67b18a29";


    /***
     * 服务号数据
     * end
     */


    /**
     * 商家小程序 start
     * */

    /**
     * appid
     * */
    public static final String MERCHANT_APP_ID = "wx0583684e7d1e1d2b";


    /**
     * APP_SECRET
     * */
    public static final String MERCHANT_APP_SECRET = "dc635f1c4e9ac4530ae6ff5ed7c79929";


    /**
     * 商户号
     * */
    public static final String MERCHANT_ID = "";

    /**
     * 商家小程序 end
     * */


    /**
     * 小指令服务号 api证书
     * api证书序列号
     * 查看方式 ： 一 登陆商户平台【API安全】->【API证书】->【查看证书】，可查看商户API证书序列号
     *           二 openssl命令行工具查看证书序列号 openssl x509 -in xxxxxxx_cert.pem -noout -serial
     */
    public static final String SERIAL_NO = "5D20BCD9314DAD4112876E4FF275054E0EB1C8F3";




}

